package org.discala.samples.complex.domain

/**
 * @author Chris Turner
 */
class Ingredient(val name: String, val aromaStrength: Float, val tasteStrength: Float) {
  
  override def equals(other: Any): Boolean =
      other match {
        case that: Ingredient =>
          (that canEqual this) &&
          this.name == that.name
        case _ => false
      }

  private def canEqual(other: Any): Boolean =
    other.isInstanceOf[Ingredient]

  override def hashCode: Int = name.hashCode
}